IsProperSupersetOf Method

Wintellect PowerCollections

Collapse imageExpand ImageCollapseAll imageExpandAll imageDropDown imageDropDownHover imageCopy imageCopyHover image
[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]

Determines if this bag is a proper superset of another bag. Neither bag is modified. This bag is a proper superset of otherBag if every element in otherBag is also in this bag, at least the same number of times. Additional, this bag must have strictly more items than otherBag.

Namespace: Wintellect.PowerCollections
Assembly:  PowerCollections (in PowerCollections.dll)

Syntax

C#
public bool IsProperSupersetOf(
	Bag<T> otherBag
)
Visual Basic (Declaration)
Public Function IsProperSupersetOf ( _
	otherBag As Bag(Of T) _
) As Boolean
Visual C++
public:
bool IsProperSupersetOf (
	Bag<T>^ otherBag
)

Parameters

otherBag
Bag<(Of <T>)>
Set to compare to.

Return Value

True if this is a proper superset of otherBag.

Remarks

IsProperSupersetOf is computed in time O(M), where M is the number of unique items in otherBag.

Exceptions

ExceptionCondition
System..::InvalidOperationExceptionThis bag and otherBag don't use the same method for comparing items.

See Also